package day0717;

import javax.swing.*;

public class Test6 {
    public static void main(String[] args) {
        JFrame win=new JFrame("羊了个羊");
        JPanel panel=new JPanel();
        panel.setLayout(null);
        JLabel label=new JLabel(new ImageIcon("images/背景.jpg"));
        label.setSize(480,800);
        label.setLocation(0,0);
        panel.add(label);
        win.add(panel);
        win.setSize(480,800);
        win.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
        win.setLocationRelativeTo(null);
        win.setVisible(true);
    }
}
